
# begin makedefs

# use=386-linux

# for main link of raw_gcl
LIBS= -lm

#The multi precision library stuff
MPFILES=$(MPDIR)/mpi-386_no_under.o $(MPDIR)/libmport.a


# root for the installation, eg /usr/local
# This would cause make install to create /usr/local/bin/gcl and
# /usr/local/lib/gcl-2-??/* with some basic files.
prefix=/usr/local

# where to place the info files
INFO_DIR=/usr/local/info/

# where to put emacs lisp files.
EMACS_SITE_LISP=/usr/share/emacs/20.7/site-lisp

# the default.el file
EMACS_DEFAULT_EL=/usr/share/emacs/20.7/site-lisp/default.el

# numerous TCL/TK variables culled from the tkConfig.sh and tclConfig.sh
# if these are found.
TK_CONFIG_PREFIX=/usr/local/lib
TK_LIBRARY=/usr/local/lib/tk8.3
TCL_LIBRARY=/usr/local/lib/tcl8.3
TK_XINCLUDES=-I/usr/X11R6/include
TK_INCLUDE=-I/usr/local/lib/../include
TCL_INCLUDE=-I/usr/local/lib/../include
TK_LIB_SPEC=-L/usr/local/lib -ltk8.3
TK_BUILD_LIB_SPEC=-L/home/wfs/src/tk8.3.2/unix -ltk8.3
TK_XLIBSW=-L/usr/X11R6/lib -lX11
TK_XINCLUDES=-I/usr/X11R6/include
TCL_LIB_SPEC=-L/usr/local/lib -ltcl8.3${TCL_DBGX}
TCL_DL_LIBS=-ldl
TCL_LIBS=-ldl -lm

NOTIFY=yes
GCC=gcc





GCLDIR=/home/wfs/cvs/gcl
SHELL=/bin/sh
MACHINE=386-linux

# notes for redhat 6.0
#  the configure should select the compiler GCC=/usr/bin/i386-glibc20-linux-gcc
#  However for the gcl-tk directory, you must use plain 'gcc' since
#  that must link with the tcl tk libs which have been compiled with it.
#  so after configure change to GCC=gcc in the gcl-tk/makefile


# Machine dependent makefile definitions for intel 386,486 running linux

LBINDIR=/usr/local/bin

OFLAG	=  -O 
LIBS	= -lm 

ODIR_DEBUG= -O4 

# This CC string will be used for compilation of the system,
# and also in the compiler::*cc* variable for later compilation of
# lisp files.
# (the -pipe is just since our file system is slow..)
CC = ${GCC} -pipe -fwritable-strings  -DVOL=volatile -I$(GCLDIR)/o -fsigned-char

# under redhat 6.1 and slackware 7.0 we needed to have this
# link be static, but should be ok with the fix to unixport/rsym_elf.c
LDCC=${CC} -static
LDCC=${CC}

# note for linuxaout on an elf machine add -b i486-linuxaout 
# CC = gcc -pipe -fwritable-strings  -DVOL=volatile -I$(GCLDIR)/o -fsigned-char -b i486-linuxaout 

# Enable the fastloading mechanism which does not use ld -A
# requires c/rel_.. machine dependent code.

RSYM	= rsym
SFASL	= $(ODIR)/sfasl.o


#MPFILES= $(MPDIR)/mpi-386d.o   $(MPDIR)/libmport.a


# When using SFASL it is good to have (si::build-symbol-table)
INITFORM=(si::build-symbol-table)

# Use symbolic links
SYMB=-s

LIBFILES=bsearch.o

# the  make to use for saved_kcp the profiler.
KCP=kcp-bsd
MPFILES=${GMP_DIR}libgmp.a


# end makedefs
GCLDIR=/home/wfs/cvs/gcl
MAXDIR=/home/wfs/cvs/maxima
PREFIX_DIR=/usr/local
EMACS_SITE_LISP=/usr/local/lib/emacs/site-lisp
INFO_DIR=/usr/local/info
MAN_DIR=/usr/local/man/man1
# end maxmakedefs


all: maxima.dvi maxima.info maxima.info-1.gz maxima.pdf



OBJS=Affine.texi Arrays.texi Command.texi Constants.texi Contexts.texi \
	Ctensor.texi Debugging.texi Differential.texi Differentiation.texi \
	Equations.texi Expressions.texi Floating.texi Function.texi \
	Groups.texi Help.texi Indices.texi Input.texi \
	Integration.texi Limits.texi Lists.texi Logarithms.texi \
	Matrices.texi Miscellaneous.texi  Number.texi \
	Numerical.texi Operators.texi Plotting.texi Polynomials.texi \
	Program.texi Rules.texi Runtime.texi Series.texi \
	Simplification.texi Special.texi Statistics.texi Symmetries.texi \
	Tensor.texi Trigonometric.texi maxima.texi xrefs.texi

OBSOLETE=None.texi

tags: ${OBJS}
	texitags ${OBJS} > TAGS

	
maxima.info maxima.info-1.gz : ${OBJS}
	makeinfo maxima.texi
#	gzip maxima.info-*

maxima.dvi: maxima.vr maxima.texi maxima.fns maxima.fn ${OBJS}
	tex maxima.texi
maxima.pdf: maxima.vr maxima.texi maxima.fns maxima.fn
	pdftex maxima.texi

maxima.vr maxima.fn:  maxima.texi ${OBJS}
	tex maxima.texi
maxima.fns: maxima.fn 
	texindex maxima.fn

install:
	if [  -d ${INFO_DIR} ] ; then true ; else mkdir ${INFO_DIR}; fi
	-if fgrep maxima ${INFO_DIR}/dir > /dev/null ; then true ; else \
	echo "* Maxima : (maxima.info).	  Maxima Symbolic Algebra and Computation." >> ${INFO_DIR}/dir ; fi
	cp *.info* ${INFO_DIR}

maxima.html: maxima_toc.html

maxima_toc.html: maxima.texi ${OBJS}
	./texi2html -split_chapter maxima.texi

maxima.notes.idx: maxima-primer.tex
	latex maxima-primer.tex

maxima-primer.dvi: maxima.notes.idx maxima-primer.tex
	latex maxima-primer.tex



install-html:
	cp *.html /d/www/maxima

clean:
	rm -f *.info* maxima.toc maxima.tp maxima.vr maxima.pg maxima.ky TAGS maxima.aux maxima.dvi maxima.fn *.log *.fn *.vr *.pg *.ky *.toc *a.ux *.dvi






